3.3.55 \(\int \frac {(e+f x) \cosh (c+d x)}{a+i a \sinh (c+d x)} \, dx\) [255]

Optimal. Leaf size=73 \[ \frac {i (e+f x)^2}{2 a f}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}-\frac {2 i f \text {PolyLog}\left (2,-i e^{c+d x}\right )}{a d^2} \]

[Out]

1/2*I*(f*x+e)^2/a/f-2*I*(f*x+e)*ln(1+I*exp(d*x+c))/a/d-2*I*f*polylog(2,-I*exp(d*x+c))/a/d^2

________________________________________________________________________________________

Rubi [A]
time = 0.08, antiderivative size = 73, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 27, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.148, Rules used = {5678, 2221, 2317, 2438} \begin {gather*} -\frac {2 i f \text {Li}_2\left (-i e^{c+d x}\right )}{a d^2}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}+\frac {i (e+f x)^2}{2 a f} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[((e + f*x)*Cosh[c + d*x])/(a + I*a*Sinh[c + d*x]),x]

[Out]

((I/2)*(e + f*x)^2)/(a*f) - ((2*I)*(e + f*x)*Log[1 + I*E^(c + d*x)])/(a*d) - ((2*I)*f*PolyLog[2, (-I)*E^(c + d
*x)])/(a*d^2)

Rule 2221

Int[(((F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_.))/((a_) + (b_.)*((F_)^((g_.)*((e_.) +
 (f_.)*(x_))))^(n_.)), x_Symbol] :> Simp[((c + d*x)^m/(b*f*g*n*Log[F]))*Log[1 + b*((F^(g*(e + f*x)))^n/a)], x]
 - Dist[d*(m/(b*f*g*n*Log[F])), Int[(c + d*x)^(m - 1)*Log[1 + b*((F^(g*(e + f*x)))^n/a)], x], x] /; FreeQ[{F,
a, b, c, d, e, f, g, n}, x] && IGtQ[m, 0]

Rule 2317

Int[Log[(a_) + (b_.)*((F_)^((e_.)*((c_.) + (d_.)*(x_))))^(n_.)], x_Symbol] :> Dist[1/(d*e*n*Log[F]), Subst[Int
[Log[a + b*x]/x, x], x, (F^(e*(c + d*x)))^n], x] /; FreeQ[{F, a, b, c, d, e, n}, x] && GtQ[a, 0]

Rule 2438

Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> Simp[-PolyLog[2, (-c)*e*x^n]/n, x] /; FreeQ[{c, d,
 e, n}, x] && EqQ[c*d, 1]

Rule 5678

Int[(Cosh[(c_.) + (d_.)*(x_)]*((e_.) + (f_.)*(x_))^(m_.))/((a_) + (b_.)*Sinh[(c_.) + (d_.)*(x_)]), x_Symbol] :
> Simp[-(e + f*x)^(m + 1)/(b*f*(m + 1)), x] + Dist[2, Int[(e + f*x)^m*(E^(c + d*x)/(a + b*E^(c + d*x))), x], x
] /; FreeQ[{a, b, c, d, e, f}, x] && IGtQ[m, 0] && EqQ[a^2 + b^2, 0]

Rubi steps

\begin {align*} \int \frac {(e+f x) \cosh (c+d x)}{a+i a \sinh (c+d x)} \, dx &=\frac {i (e+f x)^2}{2 a f}+2 \int \frac {e^{c+d x} (e+f x)}{a+i a e^{c+d x}} \, dx\\ &=\frac {i (e+f x)^2}{2 a f}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}+\frac {(2 i f) \int \log \left (1+i e^{c+d x}\right ) \, dx}{a d}\\ &=\frac {i (e+f x)^2}{2 a f}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}+\frac {(2 i f) \text {Subst}\left (\int \frac {\log (1+i x)}{x} \, dx,x,e^{c+d x}\right )}{a d^2}\\ &=\frac {i (e+f x)^2}{2 a f}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}-\frac {2 i f \text {Li}_2\left (-i e^{c+d x}\right )}{a d^2}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.02, size = 66, normalized size = 0.90 \begin {gather*} \frac {i \left (d (e+f x) \left (d (e+f x)-4 f \log \left (1+i e^{c+d x}\right )\right )-4 f^2 \text {PolyLog}\left (2,-i e^{c+d x}\right )\right )}{2 a d^2 f} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[((e + f*x)*Cosh[c + d*x])/(a + I*a*Sinh[c + d*x]),x]

[Out]

((I/2)*(d*(e + f*x)*(d*(e + f*x) - 4*f*Log[1 + I*E^(c + d*x)]) - 4*f^2*PolyLog[2, (-I)*E^(c + d*x)]))/(a*d^2*f
)

________________________________________________________________________________________

Maple [B] Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 187 vs. \(2 (64 ) = 128\).
time = 1.52, size = 188, normalized size = 2.58

method result size
risch \(\frac {i f \,x^{2}}{2 a}-\frac {i e x}{a}-\frac {2 i \ln \left ({\mathrm e}^{d x +c}-i\right ) e}{d a}+\frac {2 i \ln \left ({\mathrm e}^{d x +c}\right ) e}{d a}+\frac {2 i f c x}{d a}+\frac {i f \,c^{2}}{d^{2} a}-\frac {2 i f \ln \left (1+i {\mathrm e}^{d x +c}\right ) x}{d a}-\frac {2 i f \ln \left (1+i {\mathrm e}^{d x +c}\right ) c}{d^{2} a}-\frac {2 i f \polylog \left (2, -i {\mathrm e}^{d x +c}\right )}{a \,d^{2}}+\frac {2 i f c \ln \left ({\mathrm e}^{d x +c}-i\right )}{d^{2} a}-\frac {2 i f c \ln \left ({\mathrm e}^{d x +c}\right )}{d^{2} a}\) \(188\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((f*x+e)*cosh(d*x+c)/(a+I*a*sinh(d*x+c)),x,method=_RETURNVERBOSE)

[Out]

1/2*I*f*x^2/a-I*e*x/a-2*I/d/a*ln(exp(d*x+c)-I)*e+2*I/d/a*ln(exp(d*x+c))*e+2*I/d/a*f*c*x+I/d^2/a*f*c^2-2*I/d/a*
f*ln(1+I*exp(d*x+c))*x-2*I/d^2/a*f*ln(1+I*exp(d*x+c))*c-2*I*f*polylog(2,-I*exp(d*x+c))/a/d^2+2*I/d^2/a*f*c*ln(
exp(d*x+c)-I)-2*I/d^2/a*f*c*ln(exp(d*x+c))

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x+e)*cosh(d*x+c)/(a+I*a*sinh(d*x+c)),x, algorithm="maxima")

[Out]

1/2*f*(-I*x^2/a + 4*integrate(x/(a*e^(d*x + c) - I*a), x)) - I*e*log(I*a*sinh(d*x + c) + a)/(a*d)

________________________________________________________________________________________

Fricas [A]
time = 0.35, size = 95, normalized size = 1.30 \begin {gather*} \frac {i \, d^{2} f x^{2} - 2 i \, c^{2} f - 4 i \, f {\rm Li}_2\left (-i \, e^{\left (d x + c\right )}\right ) - 2 \, {\left (-i \, d^{2} x - 2 i \, c d\right )} e - 4 \, {\left (-i \, c f + i \, d e\right )} \log \left (e^{\left (d x + c\right )} - i\right ) - 4 \, {\left (i \, d f x + i \, c f\right )} \log \left (i \, e^{\left (d x + c\right )} + 1\right )}{2 \, a d^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x+e)*cosh(d*x+c)/(a+I*a*sinh(d*x+c)),x, algorithm="fricas")

[Out]

1/2*(I*d^2*f*x^2 - 2*I*c^2*f - 4*I*f*dilog(-I*e^(d*x + c)) - 2*(-I*d^2*x - 2*I*c*d)*e - 4*(-I*c*f + I*d*e)*log
(e^(d*x + c) - I) - 4*(I*d*f*x + I*c*f)*log(I*e^(d*x + c) + 1))/(a*d^2)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - \frac {i \left (\int \frac {e \cosh {\left (c + d x \right )}}{\sinh {\left (c + d x \right )} - i}\, dx + \int \frac {f x \cosh {\left (c + d x \right )}}{\sinh {\left (c + d x \right )} - i}\, dx\right )}{a} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x+e)*cosh(d*x+c)/(a+I*a*sinh(d*x+c)),x)

[Out]

-I*(Integral(e*cosh(c + d*x)/(sinh(c + d*x) - I), x) + Integral(f*x*cosh(c + d*x)/(sinh(c + d*x) - I), x))/a

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x+e)*cosh(d*x+c)/(a+I*a*sinh(d*x+c)),x, algorithm="giac")

[Out]

integrate((f*x + e)*cosh(d*x + c)/(I*a*sinh(d*x + c) + a), x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {\mathrm {cosh}\left (c+d\,x\right )\,\left (e+f\,x\right )}{a+a\,\mathrm {sinh}\left (c+d\,x\right )\,1{}\mathrm {i}} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((cosh(c + d*x)*(e + f*x))/(a + a*sinh(c + d*x)*1i),x)

[Out]

int((cosh(c + d*x)*(e + f*x))/(a + a*sinh(c + d*x)*1i), x)

________________________________________________________________________________________